{include="header.html"}
<!--banner-->
<div class="bannerbox">
    <a href=""><img src="{SYS_LINK}{$menuInfo.banner}" alt="{$menuInfo.menuname}"></a>
</div>
<!--content-->
<div class="content">
    <div class="location">
        当前位置：<a href="{SYS_HOST}">首页</a>
        {foreach $zhlcms::menuCrumb($mid) as $v}
        > <a href="{$v.url}">{$v.menuname}</a>
        {/foreach}
    </div>
    <!--contact-->
    <div class="c_box">
        {|$essayInfo = $zhlcms::essayInfo('article',3)}
        <div class="titlebox"><span>{$essayInfo.title}</span></div>
        <div class="contact_box">
            <p>
                <img src="{SYS_LINK}{$essayInfo.img}" alt="{$essayInfo.title}" width="480" height="218" style="margin:0 50px 0px 0px;float:left;">
                <div>电话：{$essayInfo.tel}</div>
                <div>邮箱：{$essayInfo.email}</div>
                <div>地址：{$essayInfo.address}</div>
            </p>
        </div>
    </div>
    <!--message-->
    <div class="c_box">
        <div class="titlebox"><span>给我们留言</span></div>
        <form class="message_box">
            <div><input type="text" class="message_name" placeholder="你的姓名"></div>
            <div><input type="number" class="message_tel" placeholder="你的手机号"></div>
            <div><textarea class="message_content" placeholder="留言内容不超过500字符"></textarea></div>
            <div><button id="message_btn">提交</button></div>
        </form>
    </div>
</div>
{include="footer.html"}
<script>
$('#message_btn').click(function(){
    var message_name = $('.message_name').val();
    var message_tel = $('.message_tel').val();
    var message_content = $('.message_content').val();
    if(!message_name){
        alert('你的姓名不能为空');return false;
    }else if(!message_tel){
        alert('你的手机号不能为空');return false;
    }
    $.post("{fun SYS_URL_PATH('base_msg')}",{
        title:message_name,
        mobile:message_tel,
        content:message_content,
        mould:'message',
        menu_id:'15',
        still:1

    },function(res){
        console.log(res);
        if(res.code == '10000'){
            alert('提交成功');
            //window.location.reload();
        }else{
            alert('提交失败');
        }
    },'json').error(function(e){
        alert('网络异常');
    })
})
</script>